<?php
namespace Van;

class vLog {

// 日志存储
protected static $storage = null;

public static function write($message, $sign) {

	if (!self::$storage) {
		$type               = C('LOG_TYPE');		// File
		$class              = 'Think\\Log\\Driver\\' . ucwords($type);
		$config['log_path'] = C('LOG_PATH');
		self::$storage      = new $class($config);
	}
	if (empty($destination)) {
		$destination = C('LOG_PATH') . 'v' . date('y_m_d') . '.log';
	}
	self::$storage->write('['.$sign.'] '.$message, $destination);

}


}
